<template>
	<view class="search">
	  <view class="search-input" @click="handleNavigator">{{value}}</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			};
		},
		props: {
			value: String
		},
		methods: {
			handleNavigator(){
			  // 触发父组件传递的事件
			  // this.$emit("navigator");
			  
			  // 跳转到搜索页
			  uni.navigateTo({
				  url: "/pages/search/index"
			  })
			}
		}
	}
</script>

<style lang="less">
.search{
  background: #eb4450;
  height: 100rpx;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: 0 20rpx;
}

.search-input{
  height: 80rpx;
  background: #fff;
  border-radius: 4px;
  text-align: center;
  line-height: 80rpx;
  flex: 1;
  color: #999;
}
</style>
